<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>extend</title>
  <script src="../../js/vue.js"></script>
</head>

<body>
  <div id="app">
    <!-- <div id="mount-point"></div> -->
    <!-- <profile/> -->
  </div>
  <script>
    var component = Vue.component('profile',{
      template: '<p>{{firstName}} {{lastName}} aka {{alias}}</p>',
      data: function () {
        return {
          firstName: 'Walter',
          lastName: 'White',
          alias: 'Heisenberg',
        }
      }
    });
    var Profile = Vue.extend(component)
    var instance = new Profile();
    // 挂载
    // instance.$mount('#mount-point')
    instance.$mount();
    document.body.appendChild(instance.$el)

    var vm = new Vue({
      el:'#app'
    });

  </script>
</body>

</html>